The modern electronic digital computer traces its origin to the 1950s with the large scale computers first built at universities and government laboratories, then produced by industry for commercial installations world-wide. As computers proliferated, their applications covered the spectrum from relatively mundane payroll processing to sophisticated on-line reservation systems. Today our modern society has become so dependent upon computers that it is almost impossible to function without interfacing with a computer.
It is essential, of course, that these computers be properly and correctly programmed. The literature contains several examples of the chaos with results when the computer is misprogrammed. On-line systems from stock exchanges to race tracks have halted operations until the program, or the computer, is repaired. As computer hardware has increased in reliability and typical programs have increased in size, the majority of these system malfunctions can be attributed to software errors.
As is well known, the operations of the digital computer are based upon the binary number system. Arabic numerals and alphabetic characters are stored in digital form as a series of binary digits. Several standards have been developed to ensure that all computers use the same configuration of binary digits to represent the corresponding characters. In large mainframe computers, particularly, those manufactured by IBM, the most common standard is called the Extended Binary Coded Decimal Interchange Code, better known by its acronym, EBCDIC. In most other computers the standard is the American Standard Code for Information Exchange or ASCII.
In the early days of the development of digital computers, data storage was expensive and scarce. It was thus considered useful to compress data whenever practical. One common technique for conserving storage space was to assume that the year in any given date fell within the twentieth century, and to represent that year only by its two terminal digits, dropping the initial "19". This also presented a certain symmetry in that two digits represented the month (sometimes referred to as MM), two digits represented the day (sometimes referred to as DD), and two digits represented the year (sometimes referred to as YY). A date would typically then be stored in the computer as YYMMDD.
As we approach the twenty-first century, it is no longer appropriate to assume that a computer will never have to store a representation of a date outside of the range from 1900-1999. It might seem at first glance that this fact would not require a change in storage mechanisms, since it is unlikely that a program would routinely have to deal with years in the twentieth and twenty-first centuries which have the same two terminal digits. For example, it is unlikely that a airline reservations program which must schedule reservations for 2040 would contain any data regarding flights in 1940. However, problems arise when mathematical manipulation of dates must be performed.
When it could be safely assumed that all dates in a computer program occurred in the 1900s, mathematical manipulation of dates in six-digit format was fairly straightforward. For example, if a subtraction to find the time between two dates was required, ##EQU1## For operations involving years after 1999, however, this simple operation is no longer appropriate. For example, ##EQU2##
The obvious solution to this difficulty is to carry four year digits, rather than two. However, it is not as easy as it might seem to effect this change, even though digital storage is now sufficiently inexpensive that the overhead for carrying four digits instead of two is minimal. The only certain way to make such a program change is to inspect each program, line by line, to determine if the date is employed in the operation of that routine and to modify the program accordingly. After modification, the program must then be thoroughly tested under a variety of circumstances to assure that making the modification did not affect some other part of the system. This process is expensive and time-consuming. Expert estimates have placed the cost in the neighborhood of $1 to $8 per line. In any modern computer center where many programs have been written and rewritten over the past four decades, this cost is extremely high.
As Jan. 1, 2000 approaches, this problem becomes increasingly urgent. A shortage of trained computer programmers further exacerbates the situation, making it difficult or impossible to perform such extensive modifications on all the systems in operation today.
In view of the foregoing, an object of the invention is to provide improved methods of digital data processing and, particularly, improved methods for processing dates in multiple centuries.
More particularly, an object of the invention is to provide methods that can be readily incorporated into existing computer programs, and that can be used for encoding, decoding, storing, accessing and/or processing dates in multiple centuries.
A further object of the invention is to provide such methods as do not require substantial modifications to existing data structures or source code.